<!doctype html>
<html lang="en">
	<head>
		<meta charset="utf-8">
		<meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">
		<title>Knockout.js • TodoMVC</title>
		<link href="css/base.css" rel="stylesheet">
	</head>
	<body>
		<section id="todoapp">
			<header id="header">
				<h1>todos</h1>
				<input id="new-todo" data-bind="value: current, valueUpdate: 'afterkeydown', enterKey: add" placeholder="What needs to be done?" autofocus>
			</header>
			<section id="main" data-bind="visible: todos().length">
				<input id="toggle-all" data-bind="checked: allCompleted" type="checkbox">
				<label for="toggle-all">Mark all as complete</label>
				<ul id="todo-list" data-bind="foreach: filteredTodos">
					<li data-bind="css: { completed: completed, editing: editing }">
						<div class="view">
							<input class="toggle" data-bind="checked: completed" type="checkbox">
							<label data-bind="text: title, event: { dblclick: $root.editItem }"></label>
							<button class="destroy" data-bind="click: $root.remove"></button>
						</div>
						<input class="edit" data-bind="value: title, valueUpdate: 'afterkeydown', enterKey: $root.stopEditing, selectAndFocus: editing, event: { blur: $root.stopEditing }">
					</li>
				</ul>
			</section>
			<footer id="footer" data-bind="visible: completedCount() || remainingCount()">
				<span id="todo-count">
					<strong data-bind="text: remainingCount">0</strong>
					<span data-bind="text: getLabel( remainingCount )"></span> left
				</span>
				<ul id="filters">
					<li>
						<a data-bind="css: { selected: showMode() == 'all' }" href="#/all">All</a>
					</li>
					<li>
						<a data-bind="css: { selected: showMode() == 'active' }" href="#/active">Active</a>
					</li>
					<li>
						<a data-bind="css: { selected: showMode() == 'completed' }" href="#/completed">Completed</a>
					</li>
				</ul>
				<button id="clear-completed" data-bind="visible: completedCount, click: removeCompleted">
					Clear completed (<span data-bind="text: completedCount"></span>)
				</button>
			</footer>
		</section>
		<footer id="info">
			<span data-bind="visible: todos().length">Double-click to edit a todo</span>
			<p>Original Knockout version from <a href="https://github.com/addyosmani/todomvc">TodoMvc Project</a></p>
			<p>Modified to work with WebApi by <a href="http://igorshare.wordpress.com">Igor Moochnick</a></p>
		</footer>
        <script src="Scripts/jquery-1.8.0.min.js"></script>
        <script src="Scripts/knockout-2.1.0.js"></script>
		<!--Crossroad.js -->
		<script src="app/signals.min.js"></script>
		<script src="app/crossroads.min.js"></script>
		<!-- / -->
        <script src="app/dataModels.js"></script>
		<script src="app/app.js"></script>
	</body>
</html>
